package com.myosw.dao;

import java.sql.Timestamp;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.myosw.entity.VisitlogShow;
import com.myosw.enums.UrlEnum;
import com.myosw.jdbc.common.QueryHelper;
import com.myosw.pojo.Urls;
import com.sun.org.omg.SendingContext.CodeBasePackage.URLSeqHelper;

public class UrlsDao 
{
    public Urls getUrl(String url)
	    {
    	Urls bean = new Urls();
			Map<String, Object> map = new HashMap<>();
			map.put("url", url);
			return bean.get(map );
			
		}
    
  public List<Urls> getUrls()
    {
    	Urls bean = new Urls();
			return (List<Urls>) bean.list();
		
	}
  public List<Urls> getShowUrls()
  {
  	Urls bean = new Urls();
  	Map<String, Object> map = new HashMap<>();
  	map.put("isopen", UrlEnum.Show_status.IsOpen.getValue());
  	return (List<Urls>) bean.getlist(map);
		
	}
    public List<Urls> getRunUrls()
    {
    	Urls bean = new Urls();
			Map<String, Object> map = new HashMap<String, Object>();
			map.put("isrun", UrlEnum.Run_status.IsRun.getValue());
			return (List<Urls>) bean.getlist(map );
		
	}
}
